package com.jml.activitymq.整合springboot.config;

import javax.jms.Topic;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.context.annotation.Bean;
import org.springframework.stereotype.Component;
import org.apache.activemq.command.ActiveMQTopic;

@Component
public class TopicConfig {
	@Value("${topic}")
	private String topicName;
	@Bean
	public Topic topic() {
		return new ActiveMQTopic(topicName);
	}
}

